package com.zhoutao.blog.seven.service;

import com.zhoutao.blog.seven.model.Cacheable;
import com.zhoutao.blog.seven.model.detail.BookDetail;
import com.zhoutao.blog.seven.model.response.Book;

import java.util.List;
import java.util.Optional;

public interface BookService extends Cacheable {
    /**
     * 查询全部书籍
     *
     * @return
     */
    List<BookDetail> list();

    /**
     * 通过书籍KEY查询书籍信息
     *
     * @param bookKey
     * @return
     */
    Optional<Book> findByKey(String bookKey);
}
